

package com.dog.basics.admin.controller.wishwash.admin;

import com.dog.basics.bean.dto.admin.wishwash.AdminDogHxOrderItmeRoleDto;
import com.dog.basics.bean.vo.admin.wishwash.AdminDogHxOrderItmeRoleVo;
import com.dog.basics.common.util.PageParam;
import com.dog.basics.common.util.R;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.dog.basics.bean.dto.admin.wishwash.AdminDogHxOrderItmeFromDto;
import com.dog.basics.bean.vo.admin.wishwash.AdminDogHxOrderItmeVo;

import com.dog.basics.service.wishwash.DogHxOrderItmeService;
import org.springframework.security.access.prepost.PreAuthorize;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.AllArgsConstructor;
import org.springframework.web.bind.annotation.*;


/**
 * 订单子项信息
 *
 * @author cy code generator
 * @date 2021-07-09 17:40:27
 */
@RestController
@AllArgsConstructor
@RequestMapping("/admin/orderitme" )
@Api(value = "订单信息", tags = "订单信息")
public class DogHxOrderItmeController {

    private final  DogHxOrderItmeService dogHxOrderItmeService;

    /**
     * 分页查询
     * @param page 分页对象
     * @param obj 订单子项信息
     * @return
     * @author cy code generator
     * @date 2021-07-09 17:40:27
     */
    @ApiOperation(value = "设备订单信息", notes = "admin_orderitme_view")
    @GetMapping("/page" )
    @PreAuthorize("@pms.hasPermission('admin_orderitme_view')" )
    public R<IPage<AdminDogHxOrderItmeVo>> getDogHxOrderItmePage(PageParam page, AdminDogHxOrderItmeFromDto obj) {
        return R.ok(dogHxOrderItmeService.getAdminPageList(page,obj));
    }

    /**
     * @功能描述: 订单管理
     * @author He
     * @date 2021/7/19
     */
    @ApiOperation(value = "订单管理", notes = "admin_orderitme_role")
    @GetMapping("/role/page" )
    @PreAuthorize("@pms.hasPermission('admin_orderitme_role')" )
    public R<AdminDogHxOrderItmeRoleVo> getDogHxOrderItmeRolePage(PageParam page, AdminDogHxOrderItmeRoleDto obj) {
        return R.ok(dogHxOrderItmeService.getDogHxOrderItmeRolePage(page, obj));
    }






}
